﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace AutoJob_client
{
    public partial class Form1 : Form
    {

        //
        // Main Form
        //
        public Form1()
        {
            InitializeComponent();
        }

        private void Form1_Load(object sender, EventArgs e)
        {
            notifyIconSystemTray.ShowBalloonTip(5000, "My Title", "My Text", ToolTipIcon.Info);
            notifyIconSystemTray.ContextMenuStrip.ShowItemToolTips = false;

        }


        //
        // Notify Icon
        //
        private void notifyIconSystemTray_Click(object sender, MouseEventArgs e)
        {
            //contextMenuSystemTray.Visible = true;
            contextMenuSystemTray.Show();
            contextMenuSystemTray.Left = Form1.MousePosition.X;
            contextMenuSystemTray.Top = Form1.MousePosition.Y;
        }

        //
        // Context Menu
        //
        private void contextMenuSystemTray_Opening(object sender, CancelEventArgs e)
        {
        }
        
        private void contextMenuExit_Click(object sender, EventArgs e)
        {
            this.Close();
        }
                
        private void contextMenuTest_Click(object sender, EventArgs e)
        {
            this.WindowState = FormWindowState.Normal;
            this.Opacity = .90;
        }

    }
}
